include ../Makefile-config

SUBDIRS = textures
INCLUDE = -I..
LDFLAGS += $(foreach dir, $(SUBDIRS), -L$(dir))

BINS = 
OBJS = Image.o Ray.o

.PHONY: clean subdirs $(SUBDIRS)

all: subdirs $(OBJS) $(BINS)

subdirs: $(SUBDIRS)

$(SUBDIRS):
	$(MAKE) -C $@

clean:
	rm -rf $(OBJS) $(BINS)
	for dir in $(SUBDIRS); do \
		$(MAKE) -C $$dir clean; \
	done
